Ext.define('HGMIDE.controller.RefreshController', {
	extend : 'Ext.app.Controller',
	config : {
		refs : {
			runBtn : '#refreshBtn'
		},
		control : {
			runBtn : {
				tap : 'doRefresh'
			}
		}
	},
	doRefresh : function() {
		var currentEmulatorScreen = EmulatorManager.currentEmulator;
		if (currentEmulatorScreen != null) {
			var id = EmulatorManager.currentEmulator.getId();
			var iframeId = id.substring(id.indexOf('r') + 1);
			var emulator = document.getElementById('emulatorIframe' + iframeId);
			emulator.src = emulator.src;
		}
	}
});
